package com.yy.chapter7.exception;

import com.yy.chapter7.vo.ResponseVo;
import lombok.Data;

/**
 * @author yangyao
 * @Description: 自定义异常
 * @date 2018/10/24 09:45
 */
@Data
public class MyException extends RuntimeException {
    private Integer code;

    public MyException(ResponseVo responseVo) {
        super(responseVo.getMsg());
        this.code = responseVo.getCode();
    }

}
